using System;
using System.Collections.Generic;
using System.Text;
using Barrage.Meshes.Text;

namespace Barrage.Items._2D
{
    /// <summary>
    /// Simply an item with a TextBoxMesh mesh
    /// </summary>
    public class BasicTextBox : Item
    {
        TextBoxMesh textBoxMesh;
        /// <summary>
        /// Returns the text box mesh associated to this item
        /// </summary>
        public TextBoxMesh TextBoxMesh { get { return textBoxMesh; } }
        /// <summary>
        /// Gets/Sets the text that the mesh will show
        /// </summary>
        public string Text { get { return textBoxMesh.Text; } set { textBoxMesh.Text = value; } }

        /// <summary>
        /// Inits the text box mesh and the item
        /// </summary>
        /// <param name="font">Font that the text box mesh will use</param>
        /// <param name="properties">Text box properties</param>
        public BasicTextBox(BitmapFont font, TextBoxDrawProperties properties)
        {
            textBoxMesh = new TextBoxMesh(font,properties);
            addMesh(textBoxMesh);
        }
        
    }
}
